<?php
header("Content-Type: text/html; charset=UTF-8");
session_start();
//时区设置
error_reporting(0);
date_default_timezone_set('PRC');
//first find root  不用查找 在DEFINE里面已经定义根目录
define('DIR_ROOT_P',dirname(dirname(dirname(__FILE__))));
//define config 
define(	'DOMAIN_ROOT'	,	'http://localhost/teachplatform/');//根域名
define(	'DBPREFIX'		,	'nettteach_'						);//数据表前缀
define(	'SHA'			,	'nettteach_'						);//主数据库前缀
define(	'PREFIX'		,	'nettteach_'	);//附加加密字符
//define file
define('FILE_INDEX','index.php');
//define table
//define 
define(DIR_RESOURCES,'resources');

define('TABLE_MEMBER'						,	PREFIX.'MEMBER'							);
define('TABLE_DEPARTMENT'					,	PREFIX. 'department'	                );
define('TABLE_MAJOR'						,	PREFIX. 'major'                         );
define('TABLE_VIDEOS'						,	PREFIX. 'VIDEOS'						);
define('TABLE_COURSEWARE'						,	PREFIX. 'courseware'						);
define('TABLE_CLASS'						,	PREFIX. 'class'							);
include_once(DIR_ROOT_P.'/include/functions.php');
//count script time
$scriptbegintime=fs_getmicrotime();


//加载MYSQL操作类
include_once(DIR_ROOT_P.'/include/fooee.class.mysql.php');
include(DIR_ROOT_P.'/config.php');
//初始化mysql类
$db = new db();
$db -> connect($_DB);
?>